package Chain_of_Responsibility;

public class DepartmentApprover extends Approver {
	
	public DepartmentApprover(String name) {
		super(name);
	}

	public void processRequest(PurchaseRequest purchaseRequest) {
		if (purchaseRequest.getPrice() <= 5000) {
			System.out.println(" 请求编号ID=" + purchaseRequest.getId() + "被" + this.name + "处理");
		} else {
			approver.processRequest(purchaseRequest);
		}
	}
}
